package com.example.read;

import android.annotation.SuppressLint;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.LinearLayout;
import android.widget.TextView;

import androidx.appcompat.app.AppCompatActivity;

import com.example.chenzixin.views.ChengYuActivity;
import com.example.mardan.views.CoupletActivity;
import com.example.mardan.views.MainActivity;
import com.example.mardan.views.SongciChapterActivity;
import com.example.mardan.views.TangShiActivity;
import com.example.mardan.views.YuanquActivity;
import com.example.wangxinrong.views.XiaoHuaActivity;
import com.example.wangxinrong.views.XiaoHuaPicActivity;

public class ReadActivity extends AppCompatActivity {
    private TextView mXiaoshuo, mCouplet, mSongciChapter,mYuanqu,mTangshi;

    @SuppressLint("MissingInflatedId")
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_read);

        mXiaoshuo = findViewById(R.id.xiaoshuo);
        mXiaoshuo.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(ReadActivity.this, MainActivity.class);
                startActivity(intent);
            }
        });

        mCouplet = findViewById(R.id.couplet);
        mCouplet.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(ReadActivity.this, CoupletActivity.class);
                startActivity(intent);
            }
        });

        mSongciChapter = findViewById(R.id.songci_chapter);
        mSongciChapter.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(ReadActivity.this, SongciChapterActivity.class);
                startActivity(intent);
            }
        });

        LinearLayout chengyu = findViewById(R.id.chengyu);
        chengyu.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(ReadActivity.this, ChengYuActivity.class);
                startActivity(intent);
            }
        });

        LinearLayout wenzixiaohua = findViewById(R.id.wenzixiaohua);
        wenzixiaohua.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(ReadActivity.this, XiaoHuaActivity.class);
                startActivity(intent);
            }
        });

        LinearLayout tupianxiaohua = findViewById(R.id.tupianxiaohua);
        tupianxiaohua.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(ReadActivity.this, XiaoHuaPicActivity.class);
                startActivity(intent);
            }
        });

        mYuanqu = findViewById(R.id.yuanqu);
        mYuanqu.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(ReadActivity.this, YuanquActivity.class);
                startActivity(intent);
            }
        });

        mTangshi = findViewById(R.id.tangshi);
        mTangshi.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(ReadActivity.this, TangShiActivity.class);
                startActivity(intent);
            }
        });
    }
}